package factory.abstractFactory.actual.factory;

import factory.abstractFactory.constant.FactoryType;
import factory.abstractFactory.virtual.factory.BaseFactory;

/**
 * 工厂生产类
 *
 * @author 若雨成霜
 */
public class FactoryProducer {


    public static BaseFactory getBaseFactory(FactoryType factoryType) {
        switch (factoryType) {
            case PEN:
                return new PenFactory();
            case RUN_BER:
                return new RubberFactory();
            default:
                return null;
        }
    }
}
